#!/usr/bin/python
#-*-coding:utf-8-*-

import time, datetime, unittest, cookielib
from base import *
from protocol import *
from httpDriver import *
import logConfig as log

# 执行测试的类
class interfaceSet_admin(TestCase):
    def __init__(self, cpu):
        TestCase.__init__(self, cpu)
        self.cpu = cpu
        self.test_name = u"运营管理平台"
        self.test_version = 'v1.0'
        self.test_pl = 'web'
        self.test_net = 'wifi'
        self.serverIP = cpu["data"]._const["HTTP"]["HOST"]
        self.defaultServer = self.serverIP+'/admin/'
        self.username = 'xiewei'
        self.password = 'feiniao007'

        self.caseSet = [
            #####登录#####
            (
             #>>>异常登录校验
             'interface_loginCheck_false_1','interface_loginCheck_false_2','interface_loginCheck_false_3','interface_loginCheck_false_4','interface_loginCheck_false_5','interface_loginCheck_false_6',
             'interface_loginCheck_false_7','interface_loginCheck_false_8','interface_loginCheck_false_9','interface_loginCheck_false_10','interface_loginCheck_false_11','interface_loginCheck_false_12',
             'interface_loginCheck_false_13','interface_loginCheck_false_14','interface_loginCheck_false_15','interface_loginCheck_false_16','interface_loginCheck_false_17','interface_loginCheck_false_18',
             #>>>正常登录验证
             'interface_loginCheck_true',
            ),

            #####企业监控#####
            (
             'interface_getcompanyMonitoringPage','interface_companyMonitoring_situation','interface_companyMonitoring_executeTask','interface_companyMonitoring_queryDetail',
             'interface_companyMonitoring_memberActiveSituation','interface_companyMonitoring_memberAveragePerDayFlow','interface_companyMonitoring_ModelDetail','interface_companyMonitoring_showMember','interface_companyMonitoring_queryMember',
            ),
            #####企业管理#####
            (
             #>>>企业新增
             'interface_companyAddPage',
             'interface_companyAddPage_companyAdd_false_2_1','interface_companyAddPage_companyAdd_false_2_2','interface_companyAddPage_companyAdd_false_2_3','interface_companyAddPage_companyAdd_false_2_4','interface_companyAddPage_companyAdd_false_2_5','interface_companyAddPage_companyAdd_false_2_6',#企业Code校验
             'interface_companyAddPage_companyAdd_false_3_1','interface_companyAddPage_companyAdd_false_3_2','interface_companyAddPage_companyAdd_false_3_3','interface_companyAddPage_companyAdd_false_3_4',#企业name校验
             'interface_companyAddPage_companyAdd_false_4_1','interface_companyAddPage_companyAdd_false_4_2','interface_companyAddPage_companyAdd_false_4_3','interface_companyAddPage_companyAdd_false_4_4',#企业标识校验
             'interface_companyAddPage_companyAdd_true',
            ),
            (
             #>>>企业编辑
             'interface_companyEditPage','interface_companyEditPage_queryCompany',
             'interface_companyEditPage_companyEdit_check_1','interface_companyEditPage_companyEdit_check_2','interface_companyEditPage_companyEdit_check_3','interface_companyEditPage_companyEdit_check_4',
             'interface_companyEditPage_companyEdit_check_5','interface_companyEditPage_companyEdit_check_6','interface_companyEditPage_companyEdit_check_7','interface_companyEditPage_companyEdit_check_8',
             'interface_companyEditPage_companyEdit_check_9','interface_companyEditPage_companyEdit_check_10','interface_companyEditPage_companyEdit_check_11','interface_companyEditPage_companyEdit_check_12',
             'interface_companyEditPage_companyEdit_check_13','interface_companyEditPage_companyEdit_check_14','interface_companyEditPage_companyEdit_check_15','interface_companyEditPage_companyEdit_check_16',
             'interface_companyEditPage_companyEdit_check_17','interface_companyEditPage_companyEdit_check_18',
             'interface_companyEditPage_companyEdit','interface_companyEditPage_companyAdminPasswordReset','interface_companyDel',
             ),

            #####硬件管理#####
            (
             #>>>硬件新增
             'interface_hardwareAddPage',
             'interface_hardwareAddPage_hardwareAdd_false_1','interface_hardwareAddPage_hardwareAdd_false_2','interface_hardwareAddPage_hardwareAdd_false_3','interface_hardwareAddPage_hardwareAdd_false_4','interface_hardwareAddPage_hardwareAdd_false_5',
             'interface_hardwareAddPage_hardwareAdd_true',
             'interface_hardwareEditPage','interface_hardwareEditPage_query',
             'interface_hardwareEditPage_hardwareEdit_false',
             'interface_hardwareEditPage_hardwareEdit_true',
             'interface_hardwareEditPage_hardwareDel',
             'interface_modelAddPage',
             'interface_modelAddPage_modelAdd_false_1','interface_modelAddPage_modelAdd_false_2','interface_modelAddPage_modelAdd_false_3','interface_modelAddPage_modelAdd_false_4',
             'interface_modelAddPage_modelAdd',
            ),
            (
             #>>>硬件编辑
             'interface_modelEditPage_1','interface_modelEditPage_2','interface_modelEditPage_query','interface_modelEditPage_modelDetail',
             'interface_modelEditPage_modelEdit_false_1',
             'interface_modelEditPage_modelEdit_false_2',
             'interface_modelEditPage_modelEdit_true','interface_modelEditPage_modelDel',
             ),
            #####权限管理#####
            (
             #>>>企业权限
             'interface_companyRightAddPage','interface_companyRightAddPage_companyRightAdd_false_1','interface_companyRightAddPage_companyRightAdd_true',
             'interface_companyRightEditPage','interface_companyRightEditPage_companyRightEdit_false_1','interface_companyRightEditPage_companyRightEdit_true','interface_companyRightDel',
             #>>>管理员权限
             'interface_adminRightAddPage',
             'interface_adminRightAddPage_adminRightAdd_false_1',#管理员权限新增校验（管理员权限为空情况下能新增）
             'interface_adminRightAddPage_adminRightAdd_true',
             'interface_adminRightEditPage',
             'interface_adminRightEditPage_adminRightEdit_false_1',#管理员权限编辑校验（管理员名称编辑为空能编辑成功）
             'interface_adminRightEditPage_adminRightEdit_true',
             'interface_adminRightDel',
             ),
            #####二级管理员管理#####
            (
             #>>>二级管理员新增
             'interface_adminAddPage',
             'interface_adminAddPage_adminAdd_false_1','interface_adminAddPage_adminAdd_false_2','interface_adminAddPage_adminAdd_false_3','interface_adminAddPage_adminAdd_false_4','interface_adminAddPage_adminAdd_false_5',#新增二级管理员校验
             'interface_adminAddPage_adminAdd_true',
            ),
            (
             #>>>二级管理员编辑
             'interface_adminEditPage','interface_adminEditPage_query',
             'interface_adminEditPage_adminEdit_false_1',
             'interface_adminEditPage_adminEdit_false_2','interface_adminEditPage_adminEdit_false_4','interface_adminEditPage_adminEdit_false_5',#编辑二级管理员校验
             'interface_adminEditPage_adminEdit_true',
             'interface_adminStatusChange_disable','interface_adminStatusChange_enable','interface_adminEditPage_adminPasswordReset',#二级管理员账号禁用、启用以及密码重置
             'interface_adminDel',
             ),
            #####IMEI号管理#####
            (
             'interface_searchImei','interface_searchImei_fuzzyQuery',
            ),
            #####退出登录模块#####
            (
             'interface_adminPasswordEditPage','interface_logout','interface_loginHtml',
            ),
        ]
        self.editCompanyId = 0
        self.editHardwareId = 0
        self.editModelId = 0
        self.editCompanyRightsId = 0
        self.editCompanyAdminId = 0
        self.editSecondAdminId = 0
        self.execTest()

    def outputPass(self,module,funcInfo,serial,method,url,data,expectResult,testResult):
        log.TestLog('=======================================', 'T')
        log.TestLog('PASS:         ' + module + '>>>' + funcInfo + '\t' + sys._getframe().f_code.co_name + '  (' + __name__ + ')', 'T')
        log.TestLog('----------------------------------------------------------------------', 'T')
        log.TestLog('RESULT:     ' + testResult, 'T')
        log.TestLog('USETIME:   ' + '%.3f seconds' % self.useTime, 'T')
        log.TestLog('----------------------------------------------------------------------', 'T')
        self.cpu["data"].testReportAppend(serial, funcInfo, method, url, str(data), expectResult, testResult, 'success')

    def outputFail(self,module,funcInfo,serial,method,url,data,expectResult,testResult):
        log.TestLog('=======================================', 'F')
        log.TestLog('FAIL:          ' + module + '>>>' + funcInfo + '\t' + sys._getframe().f_code.co_name + "  (" + __name__ + ")", 'F')
        log.TestLog('----------------------------------------------------------------------', 'F')
        log.TestLog('RESULT:     ' + testResult, 'F')
        log.TestLog('USETIME:   ' + '%.3f seconds' % self.useTime, 'F')
        log.TestLog('----------------------------------------------------------------------', 'F')
        self.cpu["data"].testReportAppend(serial, funcInfo, method, url, str(data), expectResult, testResult, 'fail')

    # 登录> 1.1 账号为空"",密码为"feiniao007"
    def interface_loginCheck_false_1(self):
        module         = u'登录'
        func           = u'账号为空"",密码为"feiniao007"'
        serial         = '1.1'
        funcInfo       = serial+'.'+func
        method         = 'POST'
        url            = 'http://'+self.serverIP+'/admin/login.do'
        data           = {'adminCode': '', 'password': 'feiniao007'}
        expectResult   = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response       = self.assertEqual(PyUnit_FormPost(url,data), expectResult)
        self.endTime   = time.time()
        self.useTime   = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常', u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈', u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version, u'范训山', u'Linyy')

    # 登录> 1.2 账号为空"",密码为"123"
    def interface_loginCheck_false_2(self):
        module = u'登录'
        func = u'账号为空"",密码为"123"'
        serial = '1.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': '', 'password': '123'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.3 账号中有特殊字符"!@#$%^&*()",密码为"feiniao007"
    def interface_loginCheck_false_3(self):
        module = u'登录'
        func = u'账号中有特殊字符"!@#$%^&*()",密码为"feiniao007"'
        serial = '1.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': '!@#$%^&*()', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.4 账号前有空格" xiewei",密码为"feiniao007"
    def interface_loginCheck_false_4(self):
        module = u'登录'
        func = u'账号前有空格" xiewei",密码为"feiniao007"'
        serial = '1.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': ' xiewei', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.5 正确账号中间有空格"xie wei",密码为"123456"
    def interface_loginCheck_false_5(self):
        module = u'登录'
        func = u'正确账号中间有空格"xie wei",密码为"feiniao007"'
        serial = '1.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xie wei', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.6 正确账号后有空格"xiewei ",密码为"feiniao007"
    def interface_loginCheck_false_6(self):
        module = u'登录'
        func = u'正确账号后有空格"xiewei ",密码为"feiniao007"'
        serial = '1.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei ', 'password': 'feiniao007'}
        expectResult = 100

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.7 错误的账号登录，账号为"xiewei1",密码为"feiniao007"
    def interface_loginCheck_false_7(self):
        module = u'登录'
        func = u'错误的账号登录，账号为"xiewei1",密码为"feiniao007"'
        serial = '1.7'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei1', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.8 长度小于6的账号登录，账号为"xie",密码为"feiniao007"
    def interface_loginCheck_false_8(self):
        module = u'登录'
        func = u'长度小于6的账号登录，账号为"xie",密码为"feiniao007"'
        serial = '1.8'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xie', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.9 长度大于12的账号登录，账号为"xiewei123456789",密码为"feiniao007"
    def interface_loginCheck_false_9(self):
        module = u'登录'
        func = u'长度大于12的账号登录，账号为"xiewei123456789",密码为"feiniao007"'
        serial = '1.9'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei123456789', 'password': 'feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.10 正确账号"xiewei",密码为空""
    def interface_loginCheck_false_10(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码为空""'
        serial = '1.10'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': ''}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.11 正确账号"xiewei",密码中有特殊字符,密码为"!@#$%^&*()"
    def interface_loginCheck_false_11(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码为空"!@#$%^&*()"'
        serial = '1.11'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': '!@#$%^&*()'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.12 正确账号"xiewei",密码前有空格,密码为" feiniao007"
    def interface_loginCheck_false_12(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码为空" feiniao007"'
        serial = '1.12'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': ' feiniao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.13 正确账号"xiewei",密码中间有空格,密码为"fei niao007"
    def interface_loginCheck_false_13(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码中间有空格,密码为"fei niao007"'
        serial = '1.13'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': 'fei niao007'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.14 正确账号"xiewei",密码后有空格,密码为"feiniao007 "
    def interface_loginCheck_false_14(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码后有空格,密码为"feiniao007 "'
        serial = '1.14'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': 'feiniao007 '}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.15 正确账号"xiewei",错误的密码"feiniao00"
    def interface_loginCheck_false_15(self):
        module = u'登录'
        func = u'正确账号"xiewei",错误的密码"feiniao00"'
        serial = '1.15'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': 'feiniao00 '}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.16 正确账号"xiewei",密码长度小于3位,密码为"1"
    def interface_loginCheck_false_16(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码长度小于3位,密码为"1"'
        serial = '1.16'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': '1'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.17 正确账号"xiewei",密码长度大于12位,密码为"123456789123456789"
    def interface_loginCheck_false_17(self):
        module = u'登录'
        func = u'正确账号"xiewei",密码长度大于12位,密码为"123456789123456789"'
        serial = '1.17'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': 'xiewei', 'password': '123456789123456789'}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.18 账号和密码均为空
    def interface_loginCheck_false_18(self):
        module = u'登录'
        func = u'账号和密码均为空'
        serial = '1.18'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': '', 'password': ''}
        expectResult = 0

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 登录> 1.19 正确账号和密码登录，账号为"xiewei",密码为"feiniao007"
    def interface_loginCheck_true(self):
        module = u'登录'
        func = u'正确账号和密码登录，账号为"xiewei",密码为"feiniao007"'
        serial = '1.19'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/login.do'
        data = {'adminCode': self.username, 'password': self.password}
        expectResult = 100

        self.startTime = time.time()
        self.cookies = cookielib.CookieJar()
        self.cookies.set_cookie(make_cookie("fnRemeberAdminCode", "true", self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminCode", self.username, self.defaultServer))
        self.cookies.set_cookie(make_cookie("fnAdminPassword", self.password, self.defaultServer))
        opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookies))
        urllib2.install_opener(opener)

        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # 企业监控> 1 企业监控界面获取
    def interface_getcompanyMonitoringPage(self):
        module         = u'企业监控'
        func           = u'企业监控界面获取'
        serial         = '1'
        funcInfo       = serial+'.'+func
        method         = 'GET'
        url            = 'http://'+self.serverIP+'/admin/companyMonitoring.do?timeStamp='+str(getTimestamp())
        data           = {}
        expectResult   = 100

        self.startTime = time.time()
        response       = self.assertEqual(PyUnit_PageGet(url,data), expectResult)
        self.endTime   = time.time()
        self.useTime   = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 2 企业概况数据查询
    def interface_companyMonitoring_situation(self):
        module = u'企业监控'
        func = u'企业概况数据查询'
        serial = '2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_situation.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 3 更新在线时间
    def interface_companyMonitoring_executeTask(self):
        module = u'企业监控'
        func = u'更新在线时间'
        print(u"更新在线时间开始....")
        serial = '3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_executeTask.do?timeStamp='+str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime

        print(u"更新在线时间结束....")

        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 4 企业详细信息界面的获取
    def interface_companyMonitoring_queryDetail(self):
        module = u'企业监控'
        func = u'企业详细信息界面的获取'
        serial = '4'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_queryDetail.do?companyId=169&timestamp='+str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 5 企业成员在线情况的获取
    def interface_companyMonitoring_memberActiveSituation(self):
        module = u'企业监控'
        func = u'企业成员在线情况的获取'
        serial = '5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_memberActiveSituation.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 6 企业每天流量情况的获取
    def interface_companyMonitoring_memberAveragePerDayFlow(self):
        module = u'企业监控'
        func = u'企业每天流量情况的获取'
        serial = '6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_memberAveragePerDayFlow.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 7 企业机型界面的获取
    def interface_companyMonitoring_ModelDetail(self):
        module = u'企业监控'
        func = u'企业机型界面的获取'
        serial = '7'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_ModelDetail.do?companyId=169&timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 8 企业用户界面的获取
    def interface_companyMonitoring_showMember(self):
        module = u'企业监控'
        func = u'企业用户界面的获取'
        serial = '8'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_showMember.do?companyId=169&timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业监控> 9 企业用户界面查询企业成员
    def interface_companyMonitoring_queryMember(self):
        module = u'企业监控'
        func = u'企业用户界面查询企业成员'
        serial = '9'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyMonitoring_queryMember.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # 企业管理> 1 企业新增界面获取
    def interface_companyAddPage(self):
        module = u'企业管理'
        func = u'企业新增页面获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyAddPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.1 企业新增,企业账号为空
    def interface_companyAddPage_companyAdd_false_2_1(self):
        module = u'企业管理'
        func = u'企业新增,企业账号为空'
        serial = '2.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "", "companyName": "vankey", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.2 企业新增,企业账号已经被使用,账号为"autoTest1"
    def interface_companyAddPage_companyAdd_false_2_2(self):
        module = u'企业管理'
        func = u'企业新增,企业账号已经被使用,账号为"autoTest1"'
        serial = '2.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "autoTest1", "companyName": "vankey", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.3 企业新增,企业账号长度小于6位"test"
    def interface_companyAddPage_companyAdd_false_2_3(self):
        module = u'企业管理'
        func = u'企业新增,企业账号长度小于6位"test"'
        serial = '2.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "test", "companyName": "vankey", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.4 企业新增,企业账号长度大于12位"testCompanyManagerId"
    def interface_companyAddPage_companyAdd_false_2_4(self):
        module = u'企业管理'
        func = u'企业新增,企业账号长度大于12位"testCompanyManagerId"'
        serial = '2.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testCompanyManagerId", "companyName": "vankey", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.5 企业新增,企业账号中有特殊字符"!@#$%^&*"
    def interface_companyAddPage_companyAdd_false_2_5(self):
        module = u'企业管理'
        func = u'企业新增,企业账号中有特殊字符"!@#$%^&*"'
        serial = '2.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "!@#$%^&*", "companyName": "vankey", "userLabel": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 2.6 企业新增,企业账号中有特殊字符"      "
    def interface_companyAddPage_companyAdd_false_2_6(self):
        module = u'企业管理'
        func = u'企业新增,企业账号中有特殊字符"      "'
        serial = '2.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "      ", "companyName": "vankey", "userLabel": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 3.1 企业新增,企业名称为空
    def interface_companyAddPage_companyAdd_false_3_1(self):
        module = u'企业管理'
        func = u'企业新增,企业名称为空'
        serial = '3.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 3.2 企业新增,企业名称长度大于8位
    def interface_companyAddPage_companyAdd_false_3_2(self):
        module = u'企业管理'
        func = u'企业新增,企业名称长度大于8位'
        serial = '3.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "testVankeyFan", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 3.3 企业新增,企业名称为特殊字符"!@#$%^&*"
    def interface_companyAddPage_companyAdd_false_3_3(self):
        module = u'企业管理'
        func = u'企业新增,企业名称长度大于8位'
        serial = '3.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "!@#$%^&*", "userLabel": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 3.4 企业新增,企业名称为空格"        "
    def interface_companyAddPage_companyAdd_false_3_4(self):
        module = u'企业管理'
        func = u'企业新增,企业名称为空格"        "'
        serial = '3.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "        ", "userLabel": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 4.1 企业新增,用户标识为空
    def interface_companyAddPage_companyAdd_false_4_1(self):
        module = u'企业管理'
        func = u'企业新增,用户标识为空'
        serial = '4.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "vankey", "userLabel": "",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 4.2 企业新增,用户标识长度在1到8位之间
    def interface_companyAddPage_companyAdd_false_4_2(self):
        module = u'企业管理'
        func = u'企业新增,用户标识长度在1到8位之间'
        serial = '4.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "vankey", "userLabel": "testUserLabel",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 4.3 企业新增,用户标识为特殊字符"!@#$%^&*"
    def interface_companyAddPage_companyAdd_false_4_3(self):
        module = u'企业管理'
        func = u'企业新增,用户标识为特殊字符"!@#$%^&*"'
        serial = '4.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "vankey", "userLabel": "!@#$%^&*",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 4.4 企业新增,用户标识为空格"      "
    def interface_companyAddPage_companyAdd_false_4_4(self):
        module = u'企业管理'
        func = u'企业新增,用户标识为空格"      "'
        serial = '4.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "vankey", "userLabel": "      ",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 5 企业新增,企业Code为testVankey
    def interface_companyAddPage_companyAdd_true(self):
        module = u'企业管理'
        func = u'企业新增,企业Code为testVankey'
        serial = '5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyAdd.do'
        data = {"companyCode": "testVankey", "companyName": "vankey", "userLabel": "vankey", "maxUserCount": "1000",
                "maxGroupCount": "20","linkmanName":"vankey","linkmanMobile":"18758038709","linkmanEmil":"244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editCompanyId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 6 企业编辑界面获取
    def interface_companyEditPage(self):
        module = u'企业管理'
        func = u'企业编辑界面获取'
        serial = '6'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyEditPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 7 企业编辑界面中企业信息的获取
    def interface_companyEditPage_queryCompany(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业信息的获取'
        serial = '7'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_queryCompany.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.1 企业编辑界面中企业编辑校验 > 企业账号为空
    def interface_companyEditPage_companyEdit_check_1(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 企业账号为空'
        serial = '8.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId":str(self.editCompanyId),"companyCode": "", "companyName": "vankey2", "maxUserCount": "1000",
                "maxGroupCount": "20","linkmanName":"vankey","linkmanMobile":"18758038709","linkmanEmil":"244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.2 企业编辑界面中企业编辑校验 > 企业账号长度小于6,账号为"testC"
    def interface_companyEditPage_companyEdit_check_2(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 企业账号长度小于6,账号为"testC"'
        serial = '8.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testC", "companyName": "vankey2",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.3 企业编辑界面中企业编辑校验 > 企业账号长度大于12,账号为"testCodeVankey"
    def interface_companyEditPage_companyEdit_check_3(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 企业账号长度大于12,账号为"testCodeVankey"'
        serial = '8.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testCodeVankey", "companyName": "vankey2",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.4 企业编辑界面中企业编辑校验 > 企业账号已被占用,账号为"autoTest1"
    def interface_companyEditPage_companyEdit_check_4(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 企业账号长度大于12,账号为"autoTest1"'
        serial = '8.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "autoTest1", "companyName": "vankey2",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.5 企业编辑界面中企业编辑校验 > 企业名称为空
    def interface_companyEditPage_companyEdit_check_5(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >企业名称为空'
        serial = '8.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.6 企业编辑界面中企业编辑校验 > 企业名称长度大于8，名称为"testCompanyName"
    def interface_companyEditPage_companyEdit_check_6(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >企业名称长度大于8，名称为"testCompanyName"'
        serial = '8.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "testCompanyName",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.7 企业编辑界面中企业编辑校验 > 企业名称为特殊字符，名称为"!@#$%^&*"
    def interface_companyEditPage_companyEdit_check_7(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >企业名称长度大于8，名称为"!@#$%^&*"'
        serial = '8.7'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "!@#$%^&*",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.8 企业编辑界面中企业编辑校验 > 企业名称为空格，名称为"        "
    def interface_companyEditPage_companyEdit_check_8(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >企业名称长度大于8，名称为"        "'
        serial = '8.8'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "        ",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.9 企业编辑界面中企业编辑校验 > 单组用户数为空
    def interface_companyEditPage_companyEdit_check_9(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >单组用户数为空'
        serial = '8.9'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.10 企业编辑界面中企业编辑校验 > 单组用户数超过3000
    def interface_companyEditPage_companyEdit_check_10(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >单组用户数超过3000'
        serial = '8.10'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "3001",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.11 企业编辑界面中企业编辑校验 > 最大群组数为空
    def interface_companyEditPage_companyEdit_check_11(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 >最大群组数为空'
        serial = '8.11'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.12 企业编辑界面中企业编辑校验 > 最大群组数超过500
    def interface_companyEditPage_companyEdit_check_12(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 最大群组数为空'
        serial = '8.12'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "501", "linkmanName": "vankey", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.13 企业编辑界面中企业编辑校验 > 联系人姓名为空
    def interface_companyEditPage_companyEdit_check_13(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 联系人姓名为空'
        serial = '8.13'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.14 企业编辑界面中企业编辑校验 > 联系人姓名长度超过8,姓名为"testLinkManName"
    def interface_companyEditPage_companyEdit_check_14(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 联系人姓名长度超过8,姓名为"testLinkManName"'
        serial = '8.14'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "testLinkManName", "linkmanMobile": "18758038709",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.15 企业编辑界面中企业编辑校验 > 手机号为空
    def interface_companyEditPage_companyEdit_check_15(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 手机号为空'
        serial = '8.15'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.16 企业编辑界面中企业编辑校验 > 手机号不合法，号码为"187580387091"
    def interface_companyEditPage_companyEdit_check_16(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 手机号不合法，号码为"187580387091"'
        serial = '8.16'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "187580387091",
                "linkmanEmil": "244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.17 企业编辑界面中企业编辑校验 > 邮箱为空
    def interface_companyEditPage_companyEdit_check_17(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 邮箱为空'
        serial = '8.17'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "187580387091",
                "linkmanEmil": "",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 8.18 企业编辑界面中企业编辑校验 > 邮箱为不合法,邮箱为"244#com"
    def interface_companyEditPage_companyEdit_check_18(self):
        module = u'企业管理'
        func = u'企业编辑界面中企业编辑校验 > 邮箱为不合法,邮箱为"244#com"'
        serial = '8.18'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId": str(self.editCompanyId), "companyCode": "testVankey", "companyName": "vankey",
                "maxUserCount": "1000",
                "maxGroupCount": "20", "linkmanName": "vankey", "linkmanMobile": "187580387091",
                "linkmanEmil": "244#com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 9 企业编辑,企业名称从testVankey改为testVankey2
    def interface_companyEditPage_companyEdit(self):
        module = u'企业管理'
        func = u'企业编辑,企业名称从testVankey改为testVankey2'
        serial = '9'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyEdit.do'
        data = {"companyId":str(self.editCompanyId),"companyCode": "testVankey2", "companyName": "vankey2", "maxUserCount": "1000",
                "maxGroupCount": "20","linkmanName":"vankey","linkmanMobile":"18758038709","linkmanEmil":"244969309@qq.com",
                "permissions": "{1},{2},{3},{4},{5}"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    '''
    企业编辑时直接返回500错误
    '''

    # 企业管理> 9 企业重置密码
    def interface_companyEditPage_companyAdminPasswordReset(self):
        module = u'企业管理'
        func = u'企业重置密码'
        serial = '9'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyEditPage_companyAdminPasswordReset.do'
        data = {"id":str(self.editCompanyId)}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 企业管理> 10 企业删除
    def interface_companyDel(self):
        module = u'企业管理'
        func = u'企业删除'
        serial = '10'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/companyDel.do?companyId=' + str(self.editCompanyId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 1 硬件新增界面获取
    def interface_hardwareAddPage(self):
        module = u'硬件管理'
        func = u'硬件新增界面获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.1 硬件新增，硬件编号为空
    def interface_hardwareAddPage_hardwareAdd_false_1(self):
        module = u'硬件管理'
        func = u'硬件新增，硬件编号为空'
        serial = '2.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode": "", "hardwareName": "testHard1", "netType": 1, "sideFlag": 1, "screenFlag": 1, "keyNum": 2}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.2 硬件新增，硬件编号中有特殊字符"!@#$%^"
    def interface_hardwareAddPage_hardwareAdd_false_2(self):
        module = u'硬件管理'
        func = u'硬件新增，硬件编号中有特殊字符"!@#$%^"'
        serial = '2.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode": "!@#$%^", "hardwareName": "testHard1", "netType": 1, "sideFlag": 1, "screenFlag": 1,
                "keyNum": 2}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.3 硬件新增，硬件编号长度超过32个字符"hardware123456789hardware123456789hardware123456789"
    def interface_hardwareAddPage_hardwareAdd_false_3(self):
        module = u'硬件管理'
        func = u'硬件新增，硬件编号长度超过32个字符"hardware123456789hardware123456789hardware123456789"'
        serial = '2.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode": "hardware123456789hardware123456789hardware123456789", "hardwareName": "testHard1", "netType": 1, "sideFlag": 1, "screenFlag": 1,
                "keyNum": 2}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.4 硬件新增，硬件名称为空
    def interface_hardwareAddPage_hardwareAdd_false_4(self):
        module = u'硬件管理'
        func = u'硬件新增，硬件名称为空'
        serial = '2.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode": "test1", "hardwareName": "", "netType": 1, "sideFlag": 1, "screenFlag": 1,
                "keyNum": 2}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.5 硬件新增，硬件名称长度超过32个字符"hardware123456789hardware123456789hardware123456789"
    def interface_hardwareAddPage_hardwareAdd_false_5(self):
        module = u'硬件管理'
        func = u'硬件新增，硬件名称长度超过32个字符"hardware123456789hardware123456789hardware123456789"'
        serial = '2.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode": "test1", "hardwareName": "hardware123456789hardware123456789hardware123456789", "netType": 1, "sideFlag": 1, "screenFlag": 1,
                "keyNum": 2}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 2.6 硬件新增
    def interface_hardwareAddPage_hardwareAdd_true(self):
        module = u'硬件管理'
        func = u'硬件新增'
        serial = '2.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareAddPage_hardwareAdd.do'
        data = {"hardwareCode":"test1","hardwareName":"testHard1","netType":1,"sideFlag":1,"screenFlag":1,"keyNum":2}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editHardwareId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 3.硬件编辑界面获取
    def interface_hardwareEditPage(self):
        module         = u'硬件管理'
        func           = u'硬件编辑界面获取'
        serial         = '3'
        funcInfo       = serial+'.'+func
        method         = 'GET'
        url            = 'http://'+self.serverIP+'/admin/hardwareEditPage.do?timeStamp='+str(getTimestamp())
        data           = {}
        expectResult   = 100

        self.startTime = time.time()
        response       = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime   = time.time()
        self.useTime   = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 4.硬件编辑界面版本信息的获取
    def interface_hardwareEditPage_query(self):
        module = u'硬件管理'
        func = u'硬件编辑界面版本信息的获取'
        serial = '4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareEditPage_query.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        hardwareArray = jsonAck["data"]
        for hardware in hardwareArray:
            if hardware["hardwareCode"] == "test1":
                self.editHardwareId = hardware["id"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 5.1 硬件编辑,将硬件名称改为空
    def interface_hardwareEditPage_hardwareEdit_false(self):
        module = u'硬件管理'
        func = u'硬件编辑,硬件名称为空'
        serial = '5.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareEditPage_hardwareEdit.do'
        data = {"id":self.editHardwareId,"hardwareCode":"test1","hardwareName":""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 5.2 硬件编辑,将硬件名称改为"testhard2"
    def interface_hardwareEditPage_hardwareEdit_true(self):
        module = u'硬件管理'
        func = u'硬件编辑,硬件名称为"test1"'
        serial = '5.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/hardwareEditPage_hardwareEdit.do'
        data = {"id": self.editHardwareId, "hardwareCode": "test1", "hardwareName": "testhard2"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 6 硬件删除
    def interface_hardwareEditPage_hardwareDel(self):
        module = u'硬件管理'
        func = u'硬件删除'
        serial = '6'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/hardwareEditPage_hardwareDel.do?id=' + str(self.editHardwareId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 7 机型新增界面获取
    def interface_modelAddPage(self):
        module         = u'硬件管理'
        func           = u'机型新增界面获取'
        serial         = '7'
        funcInfo       = serial+'.'+func
        method         = 'GET'
        url            = 'http://'+self.serverIP+'/admin/modelAddPage.do?timeStamp='+str(getTimestamp())
        data           = {}
        expectResult   = 100

        self.startTime = time.time()
        response       = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime   = time.time()
        self.useTime   = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 8.1 机型编号校验，机型编号为空
    def interface_modelAddPage_modelCodeCHk_false(self):
        module = u'硬件管理'
        func = u'机型编号校验，机型编号为空'
        serial = '8.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelCodeCHk.do'
        data = {"modelCode": ""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 8.2 机型编号校验，机型编号为"testmodelCode"
    def interface_modelAddPage_modelCodeCHk_true(self):
        module = u'硬件管理'
        func = u'机型编号校验，机型编号为"testmodelCode"'
        serial = '8.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelCodeCHk.do'
        data = {"modelCode": "testmodelCode"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 9.1 机型新增,机型Code为""
    def interface_modelAddPage_modelAdd_false_1(self):
        module = u'硬件管理'
        func = u'机型新增,机型Code为""'
        serial = '9.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelAdd.do'
        data = {"modelCode": "", "modelDesc": "testModelName", "hardwareCode": "T1W", "remark": ""}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editModelId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 9.2 机型新增,机型Code长度超过32位，机型为"testModelCodetestModelCodetestModelCode"
    def interface_modelAddPage_modelAdd_false_2(self):
        module = u'硬件管理'
        func = u'机型新增,机型Code长度超过32位，机型为"testModelCodetestModelCodetestModelCode"'
        serial = '9.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelAdd.do'
        data = {"modelCode": "testModelCodetestModelCodetestModelCode", "modelDesc": "testModelName", "hardwareCode": "T1W", "remark": ""}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editModelId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 9.3 机型新增,机型Code含有特殊字符,机型为"!@#$%^&*"
    def interface_modelAddPage_modelAdd_false_3(self):
        module = u'硬件管理'
        func = u'机型新增,机型Code含有特殊字符,机型为"!@#$%^&*"'
        serial = '9.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelAdd.do'
        data = {"modelCode": "!@#$%^&*", "modelDesc": "testModelName",
                "hardwareCode": "T1W", "remark": ""}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editModelId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 9.4 机型新增,机型Code含有空格,机型为"        "
    def interface_modelAddPage_modelAdd_false_4(self):
        module = u'硬件管理'
        func = u'机型新增,机型Code含有空格,机型为"        "'
        serial = '9.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelAdd.do'
        data = {"modelCode": "        ", "modelDesc": "testModelName",
                "hardwareCode": "T1W", "remark": ""}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editModelId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 9 机型新增,机型Code为"testModelCode"
    def interface_modelAddPage_modelAdd(self):
        module = u'硬件管理'
        func = u'机型新增,机型Code为"testModelCode"'
        serial = '9'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelAddPage_modelAdd.do'
        data = {"modelCode": "testModelCode", "modelDesc": "testModelName1", "hardwareCode": "s3", "remark": ""}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editModelId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 10 机型编辑界面加载
    def interface_modelEditPage_1(self):
        module = u'硬件管理'
        func = u'机型编辑界面加载'
        serial = '10'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/modelEditPage.do?status=100'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 11 机型编辑界面获取
    def interface_modelEditPage_2(self):
        module = u'硬件管理'
        func = u'机型编辑界面获取'
        serial = '11'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/modelEditPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 12 机型编辑界面机型数据的获取
    def interface_modelEditPage_query(self):
        module = u'硬件管理'
        func = u'机型编辑界面机型数据的获取'
        serial = '12'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_query.do'
        data = {"likeModel":"","start":"0","length":"10"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 13 机型编辑界面机型详情获取
    def interface_modelEditPage_modelDetail(self):
        module = u'硬件管理'
        func = u'机型编辑界面机型详情获取'
        serial = '13'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_modelDetail.do?modelCode=testModelCode&timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 14.1 机型编辑,机型名称从"testModelName1"改为""
    def interface_modelEditPage_modelEdit_false_1(self):
        module = u'硬件管理'
        func = u'机型编辑,机型名称从"testModelName1"改为""'
        serial = '14.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_modelEdit.do'
        data = {"id":self.editModelId,"modelCode":"testModelCode","modelDesc": "","remark":""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 14.2 机型编辑,机型名称从"testModelName2"改为"!@#$%^&*"
    def interface_modelEditPage_modelEdit_false_2(self):
        module = u'硬件管理'
        func = u'机型编辑,机型名称从"testModelName1"改为"!@#$%^&*"'
        serial = '14.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_modelEdit.do'
        data = {"id": self.editModelId, "modelCode": "testModelCode", "modelDesc": "!@#$%^&*","hardwareCode": "s3", "remark": ""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 14.3 机型编辑,机型名称从"testModelName1"改为"testModelName2"
    def interface_modelEditPage_modelEdit_true(self):
        module = u'硬件管理'
        func = u'机型编辑,机型名称从"testModelName1"改为"testModelName2"'
        serial = '14.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_modelEdit.do'
        data = {"id":self.editModelId,"modelCode":"testModelCode","modelDesc": "testModelName2","hardwareCode": "s3","remark":""}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 硬件管理> 15 机型删除
    def interface_modelEditPage_modelDel(self):
        module = u'硬件管理'
        func = u'机型删除'
        serial = '15'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/modelEditPage_modelDel.do?id=' + str(self.editModelId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # 权限管理> 1 企业权限新增界面的获取
    def interface_companyRightAddPage(self):
        module = u'权限管理'
        func = u'企业权限新增界面的获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyRightAddPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 2.1 企业权限名校验,企业权限名为空
    def interface_companyRightAddPage_companyRightNameCHK_false(self):
        module = u'权限管理'
        func = u'企业权限名校验,企业权限名为空'
        serial = '2.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyCodeCHK.do'
        data = {"name":""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 2.2 企业权限名校验,企业权限名为空
    def interface_companyRightAddPage_companyRightNameCHK_true(self):
        module = u'权限管理'
        func = u'企业权限名校验,企业权限名为空'
        serial = '2.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyAddPage_companyCodeCHK.do'
        data = {"name": "testRightName"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 3.1 企业权限新增,企业权限名为空
    def interface_companyRightAddPage_companyRightAdd_false_1(self):
        module = u'权限管理'
        func = u'企业权限新增,企业权限名为空'
        serial = '3.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyRightAddPage_companyRightAdd.do'
        data = {"code": "testRightsCode", "name": "", "desc": "testForFan"}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editCompanyRightsId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 3.2 企业权限新增,企业权限名为"testRightsName"
    def interface_companyRightAddPage_companyRightAdd_true(self):
        module = u'权限管理'
        func = u'企业权限新增,企业权限名为"testRightsName"'
        serial = '3.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyRightAddPage_companyRightAdd.do'
        data = {"code": "testRightsCode", "name": "testRightsName", "desc":"testForFan"}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editCompanyRightsId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 4 企业权限查询界面的获取
    def interface_companyRightEditPage(self):
        module = u'权限管理'
        func = u'企业权限查询界面的获取'
        serial = '4'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/companyRightEditPage.do?timestamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 5.1 企业权限编辑,权限名从"testRightsName"更新为""
    def interface_companyRightEditPage_companyRightEdit_false_1(self):
        module = u'权限管理'
        func = u'企业权限编辑,权限名从"testRightsName"更新为""'
        serial = '5.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyRightEditPage_companyRightEdit.do'
        data = {"id": self.editCompanyRightsId, "code": "", "name": "testRightsName1",
                "desc": "testForFan"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 5.2 企业权限编辑,权限名从"testRightsName"更新为"testRightsName1"
    def interface_companyRightEditPage_companyRightEdit_true(self):
        module = u'权限管理'
        func = u'企业权限编辑,权限名从"testRightsName"更新为"testRightsName1"'
        serial = '5.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/companyRightEditPage_companyRightEdit.do'
        data = {"id":self.editCompanyRightsId,"code": "testRightsCode1", "name": "testRightsName1", "desc": "testForFan"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 6 企业权限删除
    def interface_companyRightDel(self):
        module = u'权限管理'
        func = u'企业权限删除'
        serial = '6'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/companyRightDel.do?id=' + str(self.editCompanyRightsId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 7 管理员权限新增界面的获取
    def interface_adminRightAddPage(self):
        module = u'权限管理'
        func = u'管理员权限新增界面的获取'
        serial = '7'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminRightAddPage.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 8.1 管理员权限名校验,管理员权限名为空
    def interface_adminRightAddPage_adminRightNameCHK_false(self):
        module = u'权限管理'
        func = u'管理员权限名校验,管理员权限名为空'
        serial = '8.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightAddPage_adminRightNameCHK.do'
        data = {"name": ""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 8.2 管理员权限名校验,管理员权限名为"testAdminName"
    def interface_adminRightAddPage_adminRightNameCHK_true(self):
        module = u'权限管理'
        func = u'管理员权限名校验,管理员权限名为"testAdminName"'
        serial = '8.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightAddPage_adminRightNameCHK.do'
        data = {"name": "testAdminName"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 9.1 管理员权限新增,管理员权限名为""
    def interface_adminRightAddPage_adminRightAdd_false_1(self):
        module = u'权限管理'
        func = u'管理员权限新增,管理员权限名为""'
        serial = '9.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightAddPage_adminRightAdd.do'
        data = {"name": "", "accessUrl": "testAccessUrl", "path": "testPath", "parentId": "",
                "showFlag": "1"}
        expectResult = 0

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editCompanyAdminId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 9.2 管理员权限新增,管理员权限名为"testAdminName"
    def interface_adminRightAddPage_adminRightAdd_true(self):
        module = u'权限管理'
        func = u'管理员权限新增,管理员权限名为"testAdminName"'
        serial = '9.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightAddPage_adminRightAdd.do'
        data = {"name": "testAdminName", "accessUrl": "testAccessUrl", "path":"testPath","parentId":"","showFlag":"1"}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        self.editCompanyAdminId = jsonAck["data"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 10 管理员权限编辑界面的获取
    def interface_adminRightEditPage(self):
        module = u'硬件管理'
        func = u'管理员权限编辑界面的获取'
        serial = '10'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminRightEditPage.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 11.1 管理员权限编辑,权限名从"testAdminName"更新为""
    def interface_adminRightEditPage_adminRightEdit_false_1(self):
        module = u'权限管理'
        func = u'管理员权限编辑,权限名从"testAdminName"更新为""'
        serial = '11.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightEditPage_adminRightEdit.do'
        data = {"id": self.editCompanyAdminId, "name": "", "accessUrl": "testAccessUrl1",
                "path": "testPath1", "parentId": "", "showFlag": "1"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 11 管理员权限编辑,权限名从"testAdminName"更新为"testAdminName1"
    def interface_adminRightEditPage_adminRightEdit_true(self):
        module = u'权限管理'
        func = u'管理员权限编辑,权限名从"testAdminName"更新为"testAdminName1"'
        serial = '11'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminRightEditPage_adminRightEdit.do'
        data = {"id":self.editCompanyAdminId,"name": "testAdminName1", "accessUrl": "testAccessUrl1", "path":"testPath1","parentId":"","showFlag":"1"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 权限管理> 12 管理员权限删除
    def interface_adminRightDel(self):
        module = u'权限管理'
        func = u'管理员权限删除'
        serial = '12'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/adminRightDel.do?id=' + str(self.editCompanyAdminId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # 二级管理员管理> 1 二级管理员新增界面的获取
    def interface_adminAddPage(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增界面的获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminAddPage.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.1 二级管理账号验证,管理员账号为空
    def interface_adminAddPage_adminCodeCHk_false_1(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号为空'
        serial = '2.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": ""}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.2 二级管理账号验证,管理员账号长度小于6位为"testA"
    def interface_adminAddPage_adminCodeCHk_false_2(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号长度小于6位为"testA"'
        serial = '2.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": "testA"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.3 二级管理账号验证,管理员账号长度大于12位为"testAdminAccountlengthover12"
    def interface_adminAddPage_adminCodeCHk_false_3(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号长度大于12位为"testAdminAccountlengthover12"'
        serial = '2.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": "testAdminAccountlengthover12"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.4 二级管理账号验证,管理员账号中有特殊字符为"!@#$%^&*"
    def interface_adminAddPage_adminCodeCHk_false_4(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号中有特殊字符为"!@#$%^&*"'
        serial = '2.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": "!@#$%^&*"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.5 二级管理账号验证,管理员账号中有空格"test Admin"
    def interface_adminAddPage_adminCodeCHk_false_5(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号中有特殊字符为"test Admin'
        serial = '2.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": "test Admin"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 2.6 二级管理账号验证,管理员账号中有空格"testAdmin"
    def interface_adminAddPage_adminCodeCHk_true(self):
        module = u'二级管理员管理'
        func = u'二级管理账号验证,管理员账号中有特殊字符为"testAdmin'
        serial = '2.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminCodeCHk.do'
        data = {"adminCode": "testAdmin"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPostCheck(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.1 二级管理员新增,管理员账号为空
    def interface_adminAddPage_adminAdd_false_1(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号为空'
        serial = '3.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.2 二级管理员新增,管理员账号长度少于6位,为"testA"
    def interface_adminAddPage_adminAdd_false_2(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号长度少于6为,为"testA"'
        serial = '3.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "testA", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.3 二级管理员新增,管理员账号长度大于12位,为"testAdminSecond"
    def interface_adminAddPage_adminAdd_false_3(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号长度大于12位,为"testAdminSecond"'
        serial = '3.3'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "testAdminSecond", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.4 二级管理员新增,管理员账号中有特殊字符,为"!@#$%^&*"
    def interface_adminAddPage_adminAdd_false_4(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号中有特殊字符,为"!@#$%^&*"'
        serial = '3.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "!@#$%^&*", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.5 二级管理员新增,管理员账号为空格,为"        "
    def interface_adminAddPage_adminAdd_false_5(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号为空格,为"        "'
        serial = '3.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "        ", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 3.6 二级管理员新增,管理员账号为"testAdminC"
    def interface_adminAddPage_adminAdd_true(self):
        module = u'二级管理员管理'
        func = u'二级管理员新增,管理员账号为"testAdminC"'
        serial = '3.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminAddPage_adminAdd.do'
        data = {"adminCode": "testAdminC", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 4 二级管理员编辑界面的获取
    def interface_adminEditPage(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑界面的获取'
        serial = '4'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminEditPage.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 5 二级管理员编辑界面管理员信息的获取
    def interface_adminEditPage_query(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑界面管理员信息的获取'
        serial = '5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_query.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        jsonAck = PyUnit_FormPost_AckJson(url, data)
        for adminInfo in jsonAck["data"]:
            if adminInfo["adminCode"] == "testAdminC":
                self.editSecondAdminId = adminInfo["id"]
        response = self.assertEqual(jsonAck["status"], expectResult)
        #response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 6.1 二级管理员编辑，姓名为空
    def interface_adminEditPage_adminEdit_false_1(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑，姓名为空'
        serial = '6.1'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminEdit.do'
        data = {"id":self.editSecondAdminId,"adminCode": "testAdminC", "name": "", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 6.3 二级管理员编辑，姓名长度大于8，姓名为"testSecondAdminName"
    def interface_adminEditPage_adminEdit_false_2(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑，姓名长度大于8，姓名为"AdminName"'
        serial = '6.2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminEdit.do'
        data = {"id":self.editSecondAdminId,"adminCode": "testAdminC", "name": "testSecondAdminName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 6.4 二级管理员编辑，姓名中有特殊字符,姓名为"!@#$%^&*"
    def interface_adminEditPage_adminEdit_false_4(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑，姓名中有特殊字符,姓名为"!@#$%^&*"'
        serial = '6.4'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminEdit.do'
        data = {"id":self.editSecondAdminId,"adminCode": "testAdminC", "name": "!@#$%^&*", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 6.5 二级管理员编辑，姓名为空格,姓名为"        "
    def interface_adminEditPage_adminEdit_false_5(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑，姓名为空格,姓名为"        "'
        serial = '6.5'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminEdit.do'
        data = {"id":self.editSecondAdminId,"adminCode": "testAdminC", "name": "        ", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 0

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 6.6 二级管理员编辑，姓名"testName"
    def interface_adminEditPage_adminEdit_true(self):
        module = u'二级管理员管理'
        func = u'二级管理员编辑，姓名"testName"'
        serial = '6.6'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminEdit.do'
        data = {"id":self.editSecondAdminId,"adminCode": "testAdminC", "name": "testName", "mobile": "18758038709", "permissions": "1,2"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 7 二级管理员账号的禁用
    def interface_adminStatusChange_disable(self):
        module = u'二级管理员管理'
        func = u'二级管理员账号的禁用'
        serial = '7'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminStatusChange.do?id='+str(self.editSecondAdminId)+"&status=0&timestamp="+str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 8 二级管理员账号的启用
    def interface_adminStatusChange_enable(self):
        module = u'二级管理员管理'
        func = u'二级管理员账号的启用 '
        serial = '8'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminStatusChange.do?id='+str(self.editSecondAdminId)+"&status=1&timestamp="+str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 9 二级管理员重置密码
    def interface_adminEditPage_adminPasswordReset(self):
        module = u'二级管理员管理'
        func = u'二级管理员重置密码'
        serial = '9'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminEditPage_adminPasswordReset.do'
        data = {"id":str(self.editSecondAdminId)}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 二级管理员管理> 10 二级管理员删除
    def interface_adminDel(self):
        module = u'二级管理员管理'
        func = u'二级管理员删除'
        serial = '10'
        funcInfo = serial + '.' + func
        method = 'DELETE'
        url = 'http://' + self.serverIP + '/admin/adminDel.do?id=' + str(self.editSecondAdminId)
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormDelete(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # IMEI号管理> 1 IMEI号搜索界面的获取
    def interface_searchImei(self):
        module = u'IMEI号管理'
        func = u'IMEI号搜索界面的获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/searchImei.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # IMEI号管理> 2 IMEI号搜索界面的模糊查询的加载
    def interface_searchImei_fuzzyQuery(self):
        module = u'IMEI号管理'
        func = u'IMEI号搜索界面的模糊查询的加载'
        serial = '2'
        funcInfo = serial + '.' + func
        method = 'POST'
        url = 'http://' + self.serverIP + '/admin/searchImei_fuzzyQuery.do'
        data = {"search-imei": "358740055952484","start":"0","length":"10"}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_FormPost(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

###########################################################

    # 退出> 1 密码修改界面的获取
    def interface_adminPasswordEditPage(self):
        module = u'退出'
        func = u'密码修改界面的获取'
        serial = '1'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/adminPasswordEditPage.do?timeStamp=' + str(getTimestamp())
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 退出> 2 退出登录
    def interface_logout(self):
        module = u'退出'
        func = u'退出登录'
        serial = '2'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/logout.do'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')

    # 退出> 3 登录界面的获取
    def interface_loginHtml(self):
        module = u'退出'
        func = u'登录界面的获取'
        serial = '3'
        funcInfo = serial + '.' + func
        method = 'GET'
        url = 'http://' + self.serverIP + '/admin/login.html'
        data = {}
        expectResult = 100

        self.startTime = time.time()
        response = self.assertEqual(PyUnit_PageGet(url, data), expectResult)
        self.endTime = time.time()
        self.useTime = self.endTime - self.startTime
        if response["status"] == 1:
            self.test_success += 1
            self.outputPass(module, funcInfo, serial, method, url, data, expectResult, response["content"])
        else:
            self.test_failed += 1
            self.outputFail(module, funcInfo, serial, method, url, data, expectResult, response["content"])
            self.cpu["data"].testResultAppend(module, func, u'验证' + func + u'接口是否正常', u'网络正常',
                                              u'向服务器发起' + func + u'的请求', u'能收到到' + func + u'的预期反馈',
                                              u'没收到' + func + u'的反馈或反馈内容与预期不一致', u'缺陷', u'紧急', self.test_version,
                                              u'范训山', u'Linyy')


#if __name__ == "__main__":
#    suite = unittest.TestSuite()
#    runner = unittest.TextTestRunner()
#    runner.run(suite)

